import { Component } from '@angular/core';
import { FormsModule } from '@angular/forms';
import { NzInputModule } from 'ng-zorro-antd/input';
import { NzMentionModule } from 'ng-zorro-antd/mention';

@Component({
  selector: 'app-mention-basic-demo',
  standalone: true,
  imports: [NzMentionModule, NzInputModule, FormsModule],
  templateUrl: './mention-basic-demo.component.html',
  styleUrl: './mention-basic-demo.component.less',
})
export class MentionBasicDemoComponent {
  value = '@afc163';
  suggestions = [
    'afc163',
    'benjycui',
    'yiminghe',
    'RaoHai',
    '中文',
    'にほんご',
  ];

  onChange(value: string) {
    console.log(value);
  }

  onSelect(suggestion: string) {
    console.log(`onselect ${suggestion}`);
  }
}
